﻿<!--#include file="const.inc"-->
<%
'====================================================================
' 感谢使用晴天3G智能建站系统..
' 作者:梁永强.QQ:766750857
' 官方网址:wap.qt3g.com
' 声明:软件版权归作者所有,没有经过作者本人同意不得非法破解和传播本程序
'====================================================================
%>

<%	dim rs,sql,i,name,id,page,fleg,phonenid,body,ed
	id=Request.QueryString("id")
	if id="" then id=1
	if not isnumeric(id) then id=1
	id=clng(id)
        ed=id*4+55579
        phonenid=qingtian.phonename(midqd,1)
	Set Rs = Server.CreateObject("Adodb.Recordset")
	Sql = "select [name] from [qingtian_phonefenn] where [id]="&id
	Rs.Open Sql,conn,1,1
	if not (rs.bof and rs.eof)  then
		name=qingtian.utf8(rs("name"))
        else
                name="出错了"
	end if
	Rs.close
select case v
case "0"
we0="<br/>"
hr="------------------<br/>"
book1="<input name=""PostField1"" value=""""  size='6' emptyok=""true"" /><anchor>搜"&name&"<go href=""/search.asp?sid="&sidd&""" method=""post""><postfield name=""kw"" value=""$(PostField1)"" /></go></anchor><br/>"
%>
<card title="<%=name%>下载"><p align="<%=qingtian.px%>">
<%
case "1"
hr=""
ziz="<div style=""background-color:#FF5226;color:#E1E100;"">"
zia="<div style=""background-color:#FFDAC8;color:#D9006C;"">"
zi="<span style=""color:#FF5500"">"
zi0="</span>"
we="<div class=""footer"">"
sou="<div class=""block4"">"
dao="<div class=""navi"">"
we0="</div>"
we1="</div>"
book1=""&we&"<form action=""/search.asp?sid="&sidd&""" method=""post""><input name='kw' emptyok=""true"" maxlength='128'/><br/><input type=""submit"" value=""搜"&name&""" /></form>"&we0&""
%>
<title><%=name%>下载</title>
</head>
<body>
<!--#include virtual="/css.inc"-->
<%
End Select
if name="出错了" then qingtian.err("该文件分类还没添加!")	
%>
<%


		if sid="Null" then
		%><%=ziz%><a href="login.asp?sid=<%=sidd%>&amp;url=fileli.asp?id=<%=id%>">登陆</a>|<%=qingtian.phonetol("/fileli.asp?id="&id)%><%=we0%><%=qingtian.qingsav(ed)%><%=dao%><%=zi%><%=name%><%=zi0%><%
		else
		qingtian.info
		%><%=ziz%><a href="index.asp?sid=<%=sidd%>">首页</a>|<%=qingtian.phonetol("/fileli.asp?id="&id)%><%=we0%><%=qingtian.qingsav(ed)%><%=dao%><%=zi%><%=name%><%=zi0%><%
		end if

Sql = "select top 3 [id],[name] from [qingtian_phonefenn] where id<>"&id&" order by [id] desc"
Rs.Open Sql,conn,1,1
if not (rs.bof and rs.eof)  then
For i=1 to rs.RecordCount
		If Rs.Eof Then
			exit For
		End If
body="|<a href='fileli.asp?id="&rs("id")&"&amp;sid="&sidd&"'>"&qingtian.utf8(rs("name"))&"</a>"&body
	 	Rs.MoveNext
	  	Next
Response.Write body
end if
Rs.close
%>
<%=we0%>
<%=sou%>
<a href="downli.asp?act=1&amp;listid=<%=id%>&amp;sid=<%=sidd%>">热门</a><a href="newli.asp?act=1&amp;listid=<%=id%>&amp;sid=<%=sidd%>">新品</a><a href="tuijianli.asp?act=1&amp;listid=<%=id%>&amp;sid=<%=sidd%>">经典</a><a href="fenlei.asp?id=<%=id%>&amp;sid=<%=sidd%>">分类</a><a href="search.asp?sid=<%=sidd%>">搜索</a>
<%=we0%>
<%=we%>
<%
set rs=nothing
Set Rs = Server.CreateObject("Adodb.Recordset")
Sql = "select top 1 a.id,a.name,a.namet,a.downCount FROM qingtian_fileli a,qingtian_phoneurl b ,qingtian_phonefen c WHERE (b.bid="&phonenid&" or b.bid=0) and a.leiid=c.id and c.listid="&id&" and a.id=b.aid order by a.id desc"
Rs.Open Sql,conn,1,1
if not (rs.bof and rs.eof)  then
Response.Write(""&zi&"[新]"&zi0&"<a href='fileve.asp?id="&rs(0)&"&amp;sid="&sidd&"'>"&qingtian.utf8(rs(2))&"|"&qingtian.utf8(rs(1))&"</a><br/>")
end if
Rs.close
Sql = "select top 1 a.id,a.name,a.namet,a.downCount FROM qingtian_fileli a,qingtian_phoneurl b ,qingtian_phonefen c WHERE (b.bid="&phonenid&" or b.bid=0) and a.leiid=c.id and c.listid="&id&" and a.id=b.aid and a.downCount>0 order by a.downCount desc"
Rs.Open Sql,conn,1,1
if not (rs.bof and rs.eof)  then
Response.Write(""&zi&"[热]"&zi0&"<a href='fileve.asp?id="&rs(0)&"&amp;sid="&sidd&"'>"&qingtian.utf8(rs(2))&"|"&qingtian.utf8(rs(1))&"</a><br/>")
end if
Rs.close
Sql = "select top 1 a.id,a.name,a.namet,a.downCount FROM qingtian_fileli a,qingtian_phoneurl b ,qingtian_phonefen c WHERE (b.bid="&phonenid&" or b.bid=0) and a.leiid=c.id and c.listid="&id&" and a.id=b.aid and a.tuijian=1 order by a.downCount desc"
Rs.Open Sql,conn,1,1
if not (rs.bof and rs.eof)  then
Response.Write(""&zi&"[荐]"&zi0&"<a href='fileve.asp?id="&rs(0)&"&amp;sid="&sidd&"'>"&qingtian.utf8(rs(2))&"|"&qingtian.utf8(rs(1))&"</a>"&zi0&"<br/>")
end if
Rs.close
set rs=nothing
Set Rs = Server.CreateObject("Adodb.Recordset")
Response.Write we1
%><%=qingtian.qingsav(ed+1)%><%=hr%><%
Sql = "select id,name from qingtian_phonefen where listid="&id&" order by id desc"
Rs.Open Sql,conn,1,1
if not (rs.bof and rs.eof)  then
Response.Write zia
For i=1 to rs.RecordCount
		If Rs.Eof Then
			exit For
		End If
Response.Write("<a href='liebie.asp?listid="&rs("id")&"&amp;sid="&sidd&"'>"&qingtian.utf8(rs("name"))&"</a>")
if (i mod 5)=0 then  
Response.Write "<br/>"

end if
	 	Rs.MoveNext
	  	Next
if (rs.RecordCount mod 5)=0 then  
Response.Write we1
else
Response.Write we0
end if
 	end if
Rs.close
set rs=nothing
%><%=hr%><%=qingtian.qingsav(ed+2)%><%
Set Rs = Server.CreateObject("Adodb.Recordset")
Response.Write(""&dao&"【<a href='downli.asp?act=1&amp;listid="&id&"&amp;sid="&sidd&"'>"&qingtian.phonename(midqd,2)&name&"下载排行榜</a>】"&we0&"")
Response.Write(""&sou&"<a href='downli.asp?actt=1&amp;act=1&amp;listid="&id&"&amp;sid="&sidd&"'>周排行</a>|<a href='downli.asp?actt=2&amp;act=1&amp;listid="&id&"&amp;sid="&sidd&"'>月排行</a>|<a href='downli.asp?actt=3&amp;act=1&amp;listid="&id&"&amp;sid="&sidd&"'>总排行</a>"&we0&"")
Sql = "select top 8 a.id,a.name,a.namet,a.downCount FROM qingtian_fileli a,qingtian_phoneurl b ,qingtian_phonefen c WHERE (b.bid="&phonenid&" or b.bid=0) and a.leiid=c.id and c.listid="&id&" and a.id=b.aid and a.downCount>0 order by a.downCount desc"
Rs.Open Sql,conn,1,1
if not (rs.bof and rs.eof)  then
Response.Write we
For i=1 to 8
		If Rs.Eof Then
			exit For
		End If
Response.Write("<a href='fileve.asp?id="&rs(0)&"&amp;sid="&sidd&"'>"&qingtian.utf8(rs(2))&"|"&qingtian.utf8(rs(1))&"</a><a href='down.asp?id="&rs(0)&"&amp;sid="&sidd&"'>下载</a><br/>")
Rs.MoveNext
Next
Response.Write we1
end if
Rs.close
set rs=nothing


Set Rs = Server.CreateObject("Adodb.Recordset")
Response.Write(""&hr&""&dao&"【<a href='newli.asp?act=1&amp;listid="&id&"&amp;sid="&sidd&"'>"&qingtian.phonename(midqd,2)&name&"之新品尝鲜</a>】"&we0&"")
%><%=qingtian.qingsav(ed+3)%><%
Sql = "select top 8 a.id,a.name,a.namet,a.downCount FROM qingtian_fileli a,qingtian_phoneurl b ,qingtian_phonefen c WHERE (b.bid="&phonenid&" or b.bid=0) and a.leiid=c.id and c.listid="&id&" and a.id=b.aid order by a.id desc"
Rs.Open Sql,conn,1,1
if not (rs.bof and rs.eof)  then
Response.Write we
For i=1 to 8
		If Rs.Eof Then
			exit For
		End If
Response.Write("<a href='fileve.asp?id="&rs(0)&"&amp;sid="&sidd&"'>"&qingtian.utf8(rs(2))&"|"&qingtian.utf8(rs(1))&"</a><a href='down.asp?id="&rs(0)&"&amp;sid="&sidd&"'>下载</a><br/>")
Rs.MoveNext
Next
Response.Write we1
end if
Rs.close
set rs=nothing

Set Rs = Server.CreateObject("Adodb.Recordset")
Response.Write(""&hr&""&dao&"【<a href='tuijianli.asp?act=1&amp;listid="&id&"&amp;sid="&sidd&"'>"&qingtian.phonename(midqd,2)&name&"之本站推荐</a>】"&we0&"")
%><%=qingtian.qingsav(ed+4)%><%
Sql = "select top 8 a.id,a.name,a.namet,a.downCount FROM qingtian_fileli a,qingtian_phoneurl b ,qingtian_phonefen c WHERE (b.bid="&phonenid&" or b.bid=0) and a.leiid=c.id and c.listid="&id&" and a.id=b.aid and a.tuijian=1 order by a.downCount desc"
Rs.Open Sql,conn,1,1
if not (rs.bof and rs.eof)  then
Response.Write we
For i=1 to 8
		If Rs.Eof Then
			exit For
		End If
Response.Write("<a href='fileve.asp?id="&rs(0)&"&amp;sid="&sidd&"'>"&qingtian.utf8(rs(2))&"|"&qingtian.utf8(rs(1))&"</a><a href='down.asp?id="&rs(0)&"&amp;sid="&sidd&"'>下载</a><br/>")
Rs.MoveNext
Next
Response.Write we1
end if
Rs.close
set rs=nothing
%>
<%=qingtian.qingsav(ed+5)%>
<%=book1%>
<%=qingtian.qingsav(ed+6)%>
<%=hr%>
<%=sou%>
当前栏目:<a href='index.asp?sid=<%=sidd%>'>首页</a>-<a href='fileli.asp?id=<%=id%>&amp;sid=<%=sidd%>'><%=name%></a>
<%=we0%>
<%=hr%>
<%
end Function
%>
